inherited crdPay: TcrdPay
  Left = 427
  Top = 388
  VertScrollBar.Range = 0
  BorderStyle = bsDialog
  Caption = #1050#1072#1088#1090#1086#1095#1082#1072' '#1092#1080#1085#1072#1085#1089#1086#1074#1086#1081' '#1086#1087#1077#1088#1072#1094#1080#1080
  ClientHeight = 346
  Constraints.MinHeight = 380
  PixelsPerInch = 96
  TextHeight = 13
  inherited Panel1: TPanel
    Top = 306
  end
  object GroupBox2: TGroupBox [2]
    Left = 0
    Top = 84
    Width = 507
    Height = 158
    Align = alClient
    Caption = ' '#1054#1087#1077#1088#1072#1094#1080#1103' '
    Font.Charset = DEFAULT_CHARSET
    Font.Color = clWindowText
    Font.Height = -11
    Font.Name = 'MS Sans Serif'
    Font.Style = [fsBold]
    ParentFont = False
    TabOrder = 2
    object Label4: TLabel
      Left = 76
      Top = 18
      Width = 19
      Height = 13
      Alignment = taRightJustify
      Caption = #1058#1080#1087
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      ParentFont = False
    end
    object Label5: TLabel
      Left = 61
      Top = 57
      Width = 34
      Height = 13
      Alignment = taRightJustify
      Caption = #1057#1091#1084#1084#1072
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      ParentFont = False
    end
    object Label6: TLabel
      Left = 69
      Top = 76
      Width = 26
      Height = 13
      Alignment = taRightJustify
      Caption = #1044#1072#1090#1072
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      ParentFont = False
    end
    object Label7: TLabel
      Left = 52
      Top = 95
      Width = 43
      Height = 13
      Alignment = taRightJustify
      Caption = #1055#1088#1080#1085#1103#1090#1086
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      ParentFont = False
    end
    object Label8: TLabel
      Left = 51
      Top = 115
      Width = 44
      Height = 13
      Alignment = taRightJustify
      Caption = #1047#1072#1084#1077#1090#1082#1080
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      ParentFont = False
    end
    object Label9: TLabel
      Left = 23
      Top = 38
      Width = 72
      Height = 13
      Alignment = taRightJustify
      Caption = #1052#1077#1089#1090#1086' '#1086#1087#1083#1072#1090#1099
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      ParentFont = False
    end
    object lDeleted: TLabel
      Left = 51
      Top = 137
      Width = 44
      Height = 13
      Alignment = taRightJustify
      Caption = #1059#1076#1072#1083#1077#1085#1086
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      ParentFont = False
    end
    object DBLookupComboboxEh1: TDBLookupComboboxEh
      Left = 100
      Top = 14
      Width = 313
      Height = 19
      AlwaysShowBorder = True
      DataField = 'TYPE_ID'
      DataSource = dscPay
      EditButtons = <>
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      Flat = True
      KeyField = 'ID'
      ListField = 'NAME'
      ListSource = dscTypes
      ParentFont = False
      ShowHint = True
      TabOrder = 0
      Visible = True
    end
    object DBEditEh4: TDBEditEh
      Left = 100
      Top = 54
      Width = 77
      Height = 19
      AlwaysShowBorder = True
      DataField = 'SUMMA'
      DataSource = dscPay
      EditButtons = <>
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      Flat = True
      ParentFont = False
      ShowHint = True
      TabOrder = 1
      Visible = True
    end
    object DBDateTimeEditEh1: TDBDateTimeEditEh
      Left = 100
      Top = 74
      Width = 77
      Height = 19
      AlwaysShowBorder = True
      DataField = 'PAYDATE'
      DataSource = dscPay
      EditButtons = <>
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      Flat = True
      Kind = dtkDateEh
      ParentFont = False
      ShowHint = True
      TabOrder = 2
      Visible = True
    end
    object DBCheckBoxEh1: TDBCheckBoxEh
      Left = 100
      Top = 93
      Width = 19
      Height = 17
      AlwaysShowBorder = True
      Color = clBtnFace
      DataField = 'IS_ACCEPTED'
      DataSource = dscPay
      Flat = True
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      ParentColor = False
      ParentFont = False
      TabOrder = 3
      ValueChecked = '1'
      ValueUnchecked = '0'
    end
    object DBEditEh5: TDBEditEh
      Left = 100
      Top = 112
      Width = 400
      Height = 19
      AlwaysShowBorder = True
      DataField = 'NOTES'
      DataSource = dscPay
      EditButtons = <>
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      Flat = True
      ParentFont = False
      ShowHint = True
      TabOrder = 4
      Visible = True
    end
    object DBLookupComboboxEh2: TDBLookupComboboxEh
      Left = 100
      Top = 34
      Width = 313
      Height = 19
      AlwaysShowBorder = True
      DataField = 'PAYSOURCE_ID'
      DataSource = dscPay
      EditButtons = <>
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      Flat = True
      KeyField = 'ID'
      ListField = 'NAME'
      ListSource = dscPaySource
      ParentFont = False
      ShowHint = True
      TabOrder = 5
      Visible = True
    end
    object cbDeleted: TDBCheckBoxEh
      Left = 100
      Top = 135
      Width = 19
      Height = 17
      AlwaysShowBorder = True
      Color = clBtnFace
      DataField = 'IS_DELETED'
      DataSource = dscPay
      Flat = True
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      ParentColor = False
      ParentFont = False
      TabOrder = 6
      ValueChecked = '1'
      ValueUnchecked = '0'
    end
  end
  object GroupBox3: TGroupBox [3]
    Left = 0
    Top = 242
    Width = 507
    Height = 64
    Align = alBottom
    Caption = ' '#1057#1083#1091#1078#1077#1073#1085#1099#1077' '#1076#1072#1085#1085#1099#1077' '
    Font.Charset = DEFAULT_CHARSET
    Font.Color = clWindowText
    Font.Height = -11
    Font.Name = 'MS Sans Serif'
    Font.Style = [fsBold]
    ParentFont = False
    TabOrder = 3
    object Label10: TLabel
      Left = 26
      Top = 20
      Width = 43
      Height = 13
      Alignment = taRightJustify
      Caption = #1057#1086#1079#1076#1072#1085#1086
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      ParentFont = False
    end
    object Label11: TLabel
      Left = 17
      Top = 42
      Width = 52
      Height = 13
      Alignment = taRightJustify
      Caption = #1048#1079#1084#1077#1085#1077#1085#1086
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      ParentFont = False
    end
    object DBEditEh6: TDBEditEh
      Left = 80
      Top = 18
      Width = 121
      Height = 19
      AlwaysShowBorder = True
      Color = clBtnFace
      DataField = 'CREATOR'
      EditButtons = <>
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      Flat = True
      ParentFont = False
      ReadOnly = True
      ShowHint = True
      TabOrder = 0
      Visible = True
    end
    object DBEditEh7: TDBEditEh
      Left = 202
      Top = 18
      Width = 73
      Height = 19
      AlwaysShowBorder = True
      Color = clBtnFace
      DataField = 'CREATEDATE'
      EditButtons = <>
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      Flat = True
      ParentFont = False
      ReadOnly = True
      ShowHint = True
      TabOrder = 1
      Visible = True
    end
    object DBEditEh8: TDBEditEh
      Left = 202
      Top = 40
      Width = 73
      Height = 19
      AlwaysShowBorder = True
      Color = clBtnFace
      DataField = 'MODIFYDATE'
      EditButtons = <>
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      Flat = True
      ParentFont = False
      ReadOnly = True
      ShowHint = True
      TabOrder = 2
      Visible = True
    end
    object DBEditEh9: TDBEditEh
      Left = 80
      Top = 40
      Width = 121
      Height = 19
      AlwaysShowBorder = True
      Color = clBtnFace
      DataField = 'MODIFIER'
      EditButtons = <>
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      Flat = True
      ParentFont = False
      ReadOnly = True
      ShowHint = True
      TabOrder = 3
      Visible = True
    end
  end
  inherited ActionList1: TActionList
    inherited aReports: TAction
      Visible = False
    end
  end
  inherited PropStorageEh1: TPropStorageEh
    Section = 'crdPay'
  end
  object dsGetDebt: TpFIBDataSet
    SelectSQL.Strings = (
      'select'
      '  rp.debt_id'
      'from rst_pays rp'
      'where rp.id = :ppay_id')
    Transaction = trCard
    Database = MAINDM.MainDB
    CSMonitorSupport.Enabled = csmeTransactionDriven
    Left = 286
    Top = 122
    object dsGetDebtDEBT_ID: TFIBIntegerField
      FieldName = 'DEBT_ID'
    end
  end
  object dsPay: TpFIBDataSet
    UpdateSQL.Strings = (
      'UPDATE RST_PAYS'
      'SET '
      '    DEBT_ID = :DEBT_ID,'
      '    TYPE_ID = :TYPE_ID,'
      '    PAYDATE = :PAYDATE,'
      '    SUMMA = :SUMMA,'
      '    IS_ACCEPTED = :IS_ACCEPTED,'
      '    NOTES = :NOTES,'
      '    PAYSOURCE_ID = :PAYSOURCE_ID,'
      '    IS_DELETED = :IS_DELETED'
      'WHERE'
      '    ID = :OLD_ID'
      '    ')
    DeleteSQL.Strings = (
      'DELETE FROM'
      '    RST_PAYS'
      'WHERE'
      '        ID = :OLD_ID'
      '    ')
    InsertSQL.Strings = (
      'INSERT INTO RST_PAYS('
      '    DEBT_ID,'
      '    TYPE_ID,'
      '    PAYDATE,'
      '    SUMMA,'
      '    IS_ACCEPTED,'
      '    NOTES,'
      '    PAYSOURCE_ID,'
      '    IS_DELETED'
      ')'
      'VALUES('
      '    :DEBT_ID,'
      '    :TYPE_ID,'
      '    :PAYDATE,'
      '    :SUMMA,'
      '    :IS_ACCEPTED,'
      '    :NOTES,'
      '    :PAYSOURCE_ID,'
      '    :IS_DELETED'
      ')')
    RefreshSQL.Strings = (
      'SELECT'
      '    rp.ID,'
      '    rp.DEBT_ID,'
      '    rp.TYPE_ID,'
      '    rp.PAYDATE,'
      '    rp.SUMMA,'
      '    rp.IS_ACCEPTED,'
      '    rp.NOTES,'
      '    rp.paysource_id,'
      '    rp.is_deleted,'
      
        '    (select rname from PR_GET_USER_NAME(rp.createuserid)) as cre' +
        'ator,'
      '    rp.createdate,'
      
        '    (select rname from PR_GET_USER_NAME(rp.modifyuserid)) as mod' +
        'ifier,'
      '    rp.modifydate'
      'FROM'
      '    RST_PAYS rp'
      'where(  rp.id = :ppay_id'
      '     ) and (     RP.ID = :OLD_ID'
      '     )'
      '    ')
    SelectSQL.Strings = (
      'SELECT'
      '    rp.ID,'
      '    rp.DEBT_ID,'
      '    rp.TYPE_ID,'
      '    rp.PAYDATE,'
      '    rp.SUMMA,'
      '    rp.IS_ACCEPTED,'
      '    rp.NOTES,'
      '    rp.paysource_id,'
      '    rp.is_deleted,'
      
        '    (select rname from PR_GET_USER_NAME(rp.createuserid)) as cre' +
        'ator,'
      '    rp.createdate,'
      
        '    (select rname from PR_GET_USER_NAME(rp.modifyuserid)) as mod' +
        'ifier,'
      '    rp.modifydate'
      'FROM'
      '    RST_PAYS rp'
      'where rp.id = :ppay_id')
    AfterOpen = dsPayAfterOpen
    Transaction = trCard
    Database = MAINDM.MainDB
    CSMonitorSupport.Enabled = csmeTransactionDriven
    Left = 286
    Top = 88
    object dsPayID: TFIBIntegerField
      FieldName = 'ID'
    end
    object dsPayDEBT_ID: TFIBIntegerField
      FieldName = 'DEBT_ID'
    end
    object dsPayTYPE_ID: TFIBIntegerField
      FieldName = 'TYPE_ID'
    end
    object dsPayPAYDATE: TFIBDateField
      FieldName = 'PAYDATE'
    end
    object dsPaySUMMA: TFIBBCDField
      FieldName = 'SUMMA'
      Size = 2
      RoundByScale = True
    end
    object dsPayIS_ACCEPTED: TFIBSmallIntField
      FieldName = 'IS_ACCEPTED'
    end
    object dsPayNOTES: TFIBStringField
      FieldName = 'NOTES'
      Size = 255
      EmptyStrToNull = True
    end
    object dsPayPAYSOURCE_ID: TFIBIntegerField
      FieldName = 'PAYSOURCE_ID'
    end
    object dsPayIS_DELETED: TFIBSmallIntField
      FieldName = 'IS_DELETED'
    end
  end
  object dsTypes: TpFIBDataSet
    SelectSQL.Strings = (
      'SELECT'
      '    ID,'
      '    NAME,'
      '    CSIGN,'
      '    ISPAY'
      'FROM'
      '    SPR_PAY_TYPES ')
    Transaction = trCard
    Database = MAINDM.MainDB
    CSMonitorSupport.Enabled = csmeTransactionDriven
    Left = 286
    Top = 52
  end
  object dscTypes: TDataSource
    DataSet = dsTypes
    Left = 324
    Top = 52
  end
  object dscPay: TDataSource
    DataSet = dsPay
    OnDataChange = dscPayDataChange
    Left = 324
    Top = 88
  end
  object dsPaySource: TpFIBDataSet
    SelectSQL.Strings = (
      'SELECT'
      '    ID,'
      '    NAME'
      'FROM'
      '    SPR_PAYSOURCE ')
    Transaction = trCard
    Database = MAINDM.MainDB
    CSMonitorSupport.Enabled = csmeTransactionDriven
    Left = 290
    Top = 160
  end
  object dscPaySource: TDataSource
    DataSet = dsPaySource
    Left = 328
    Top = 160
  end
end
